/**
 * Created by Administrator on 2017/3/14 0014.
 */
ShaderFB={
    Create:function(){
        var shader={};
        var whole=new PIXI.DisplayObjectContainer();

        var logo=PIXI.Sprite.fromImage("http://www.goodboydigital.com/pixijs/pixi_v3_github-pad.png");
        logo.x=740/2;
        logo.y=1136/2;
        logo.anchor.set(0.5);


        whole.addChild(logo);

        // var shaderCode=document.getElementById("shader").innerHTML;
        // var simpleShader=new PIXI.AbstractFilter('',shaderCode);
        // logo.filters=[simpleShader];

        uniforms={};
        uniforms.time = {type: 'f',value: 0};

        var width = window.innerWidth;
        var height = window.innerHeight;

        var uniforms={};
        uniforms.time={type:"f", value:0};
        uniforms.resolution = { type: 'v2', value: { x: width, y: height}};
        var shaderCode=document.getElementById("shader").innerHTML;
        var simpleShader=new PIXI.AbstractFilter('',shaderCode,uniforms);
        logo.filters=[simpleShader];




        shader.DoIt=function(){
            uniforms.time.value+=0.1;
        };



        shader.ReturnWhole=function(){
            return whole;
        };
        return shader;
    }
}
